x86/mm: Avoid NULL dereference when checking altp2m's for shareability
authorAndrew Cooper <andrew.cooper3@citrix.com>
Wed, 27 Jul 2016 17:54:16 +0000 (18:54 +0100)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Mon, 1 Aug 2016 16:44:32 +0000 (17:44 +0100)
commit3b54cffcdf86485dd336f71419d3bfc7106ca56c
treeb814d03cba22ee3390da63bb8f151743d16910be
parent6d61981d3619c6bad6134c2dac9774c00acca4fd
x86/mm: Avoid NULL dereference when checking altp2m's for shareability

Coverity identifies that __get_gfn_type_access() unconditionally writes to its
type parameter under a number of circumstances.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: George Dunlap <george.dunlap@citrix.com>
xen/arch/x86/mm/mem_sharing.c